A common means of sensing movement is by interruption of a light beam with an opaque body so as to effect an electrical response in a photosensitive element. The compact and convenient device for this purpose is a photocoupler which may comprise a light emitting diode, LED, for the light source and a phototransistor for the light sensitive element. These components when placed in close proximity with the carrier bearing spaced indicia as for example by slotting or perforating the carrier body, being installed between them can provide an electrical indication of motion. As the carrier which may be moved, the resulting series of light interruptions provide a series of electrical impulses from the phototransistor. In such an application it is important that the photocoupler output is maintained constant for controlling purposes. Unfortunately, however, the electrical stability of both the light emitting diode and the phototransistor is less than that required for many applications. For example, it is not uncommon for the quantum efficiency of LED's to vary with temperature changes, current changes and to vary from one device to another. The light sensitivity of phototransistors varies also with operating conditions and from device to device. An overall gain, herein defined as the product of the ratio of light intensity to LED current and the ratio of incident light to phototransistor output current, may vary as much as 100 to 1. This makes it difficult to establish a threshold for the phototransistor current which separates the light condition from the dark condition. A manual adjustment such as by a potentiometer adjustment, provides inadequate protection against short term drift such as one might expect from either temperature change or variation in ambient lighting. Where the relative motion of the indicia carrying carrier and the photocouplers is constant, it may be possible to compare the amplitude of the resulting periodic wave form from the photocoupler with a reference and use the result to automatically adjust the drive current in the light source. However, where the motion is not constant as in the movement of for example a print head carriage, no such simple comparison is suitable. The problem is made even more acute when the relative motion of the photocoupler and the indicia carrying carrier includes starting and stopping.
It is an object of the present invention to provide an improved photocoupler arrangement for sensing modulation of a light beam with a body so as to effect an electrical response in a photosensitive element.
Another object of this invention is to provide improved circuitry for automatically adjusting photocoupler operation used with a moving indicia carrier.
Another object of the invention is to provide an improved photocoupler circuit operative to accurately establish the position of indicia carried on a carrier.
In accordance with one embodiment of the present invention, means are provided for determining when the light transmission in a photocoupler is maximum. When light transmission is at maximum, the current in the LED is corrected to cause the photocell output current to match a reference value. The value of LED current is stored digitally in a register and maintained until the condition for maximum light transfer occurs. At this point comparisons of the LED current value and a reference value take place and the stored value of the LED current modified in order to maintain a constant photocoupler output for varying operating conditions.
A complete understanding of the invention and a fuller appreciation of its objects and features will be available from the following detailed description which is made in conjunction with the drawing of a particular illustrative embodiment.